import request from '../utils/request';

//作为参数返回回来
export const saveArticle = payload => request('/api/articles/add',{
  method:'POST',
  body: payload
})

export async function fetchLatestApi() {
    return request('/api/articles/latest');
}

export async function displayArticle(articleId){
  console.log(articleId);
  return request(`/api/articles/show/${articleId}`)
}
